@import '@styles/variables.scss';
@import '@styles/mixins.scss';

.rename-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;

    &__overlay {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.5);
    }

    &__content {
        position: relative;
        width: 100%;
        max-width: 400px;
        background: $background-primary;
        border-radius: $border-radius-lg;
        box-shadow: $shadow-lg;
        padding: 24px;
        z-index: 1;
    }

    &__header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 16px;
    }

    &__title {
        font-size: $font-size-lg;
        font-weight: $font-weight-medium;
        color: $text-primary;
        margin: 0;
    }

    &__close {
        background: none;
        border: none;
        color: $text-secondary;
        cursor: pointer;
        padding: 4px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: $border-radius-sm;
        transition: all $transition-fast $easing-ease;

        &:hover {
            background: $background-secondary;
            color: $text-primary;
        }

        i {
            font-size: 20px;
        }
    }

    &__form {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }

    &__input {
        width: 100%;
        padding: 8px 12px;
        border: 1px solid $border-color;
        border-radius: $border-radius-md;
        font-size: $font-size-sm;
        color: $text-primary;
        background: $background-primary;
        transition: all $transition-fast $easing-ease;

        &:focus {
            outline: none;
            border-color: $primary-color;
        }

        &::placeholder {
            color: $text-tertiary;
        }
    }

    &__actions {
        display: flex;
        justify-content: flex-end;
        gap: 8px;
    }

    &__button {
        padding: 8px 16px;
        border-radius: $border-radius-md;
        font-size: $font-size-sm;
        font-weight: $font-weight-medium;
        cursor: pointer;
        transition: all $transition-fast $easing-ease;

        &--cancel {
            background: $background-secondary;
            border: 1px solid $border-color;
            color: $text-secondary;

            &:hover {
                background: darken($background-secondary, 5%);
            }
        }

        &--submit {
            background: $primary-color;
            border: 1px solid $primary-color;
            color: white;

            &:hover {
                background: $primary-hover;
                border-color: $primary-hover;
            }
        }
    }
}